<% @page_title = "My Jobs" %>
<%= render :partial => 'users/menu' %>

<div class="column span-16 prepend-3 last">

<h3>My Jobs</h3>

<hr />

<% for job in @jobs %>
    <h4><b><%=h job.position %> at <%=h job.institution %></b> <%=h month_year(job.start_date) %> to <%=h month_year(job.end_date) %></h4>
    <h4><%=h job.city %> <% unless job.state.blank? %>, <%=h job.state %><% end %></h4>
    <p><span class="edit"><%= link_to 'Edit', edit_job_path(job) %></span> <span class="delete"><%= link_to 'Delete', job_path(job), :confirm => 'Are you sure?', :method => :delete %></span></p>
<% end %>

<% if @jobs.empty?  %>
  <p>You have not created any jobs yet.</p>
<% end %>
<hr />

<%= button_to 'Add a New Job', new_job_path, :method => :get %>

</div>
